package cn.edu.cug.cs.gtl.oi.ui.actions;

import java.io.File;
import javax.swing.filechooser.FileFilter;

public class H3DFileFilter extends FileFilter {
    @Override
    public String getDescription() {
        return "H3D files";
    }

    @Override
    public boolean accept(File f) {
        if (f == null)
            return false;
        if (f.isDirectory())
            return true;
        return f.getName().toLowerCase().endsWith(".h3d");
    }
}